Benefits of Cascading Style Sheets

Using Style Sheets

Style Sheets, or Cascading Style Sheets, are a very powerful tool for the web site developer. They allow you to take control over the look and feel of the web pages andto create a consistent design, layout, and color scheme throughout your entire site. The capabilities of style sheets have expanded greatly over the years giving the designer much more control over the appearance of their sites. Originally when HTML was first invented, style was not a consideration therefore tags were added into later releases of HTML that could add style and color to a web site, but the purpose of HTML was to define the structure of the page, not to incorporate style. Eventually Style Sheets were released as a tool to incorporate style into a web site and to take away the styling duties of HTML. As Style Sheets became more and more powerful, many of the non-structural HTML tags became obsolete and some current browser releases have even stopped recognizing them altogether. Cascading Style Sheets can be applied to a web site at three different levels:

External style Sheet
External Style Sheets allow you to create a master style file where you can define all the styles for your entireweb site. Any styles that are used on multiple pages of a website should be defined on the external style sheet. The external style sheet is attached to a web page using the link tab.
Embedded Style Sheet
An embedded style sheet should include styles that only apply to a single page. Any styles that are only used on one page should not be included on the external style sheet because it increases the size of the style sheet and is unnecessarily loaded by all the other pages of your site.
Inline Style Sheet
An inline style sheet is used to add a style to a specific tag as an attribute. The inline style will only work on the tag it is applied to and will not affect any other tags.